public class Man extends Person{
    Woman wife;

    public Man(Woman wife) {
        this.wife = wife;
    }

    public Man(String name, int age, String idNum, Woman wife) {
        super(name, age, idNum);
        this.wife = wife;
    }

    public Man() {
    }

    public Woman getWife() {
        return wife;
    }

    public void setWife(Woman wife) {
        this.wife = wife;
    }

    @Override
    public String toString() {
        return "Man{" +
                "wife=" + wife +
                ", name='" + name + '\'' +
                ", age=" + age +
                ", idNum='" + idNum + '\'' +
                '}';
    }
}
